//
// Created by 紫霄 on 2020/4/10.
//

#ifndef LEETCODE_11_H
#define LEETCODE_11_H

#include <vector>
using namespace std;

class Solution {
public:
  int minArray(vector<int> &numbers) {
    int sz = numbers.size();
    for (int i = 0; i < sz - 1; ++i) {
      if (numbers[i] > numbers[i + 1]) {
        return numbers[i + 1];
      }
    }
    return numbers[0];
  }
};
#endif // LEETCODE_11_H
